/*** Eclipse Class Decompiler plugin, copyright (c) 2012 Chao Chen (cnfree2000@hotmail.com) ***/
package com.qihoopp.qcoinpay;

import com.qihoopp.framework.HttpLoaderCallback;
import com.qihoopp.framework.LogUtil;
import org.json.JSONObject;

final class av implements HttpLoaderCallback {
    public final void callback(int paramInt, JSONObject paramJSONObject) {
        QcoinActivity.a(this.a).a();
        if (paramInt == 2) {
            this.a.a(a.a(b.bj));
        }
        else if (paramInt == 3) {
            this.a.a(a.a(b.bl));
        }
        else if (paramInt == 5) {
            this.a.a(a.a(b.bi));
        }
        else if (paramInt == 4) {
            this.a.a(a.a(b.bh));
        }
        else if ((paramInt != -1) && (paramInt == 1)) {
            paramInt = null;
            String str1 = null;
            String str2 = null;
            String str3 = a.a(b.t);
            if (paramJSONObject != null) {
                LogUtil.d("QcoinActivity", "PayAfterResetPwd json is : " + paramJSONObject.toString());
                try {
                    paramInt = paramJSONObject.getString("result_code");
                    str1 = paramJSONObject.getString("result_msg");
                    paramJSONObject = null;
                    str2 = paramJSONObject.getJSONObject("record").getString("mer_trade_code");
                } catch (java.lang.Exception paramJSONObject) {
                    LogUtil.e("QcoinActivity", "Exception", paramJSONObject);
                }
            }
            if ((str1 != null) && (!(str1.equals(""))))
                str3 = str1;
            if (paramInt != null)
                if (paramInt.equals("0000")) {
                    QcoinActivity.a(this.a, str2);
                    QcoinActivity.b(this.a, QcoinActivity.c(this.a));
                }
                else {
                    if (paramInt.equals("8805")) {
                        this.a.a(str3, false);
                        QcoinActivity.f(this.a).c();
                        if (QcoinActivity.a(this.a).d.a()) {
                            LogUtil.e("---", "normal");
                            QcoinActivity.a(this.a).d.g.a(0);
                            return;
                        }
                        LogUtil.e("---", "nomore");
                        QcoinActivity.a(this.a).d.g.a(2);
                        return;
                    }
                    this.a.a(str3);
                }
            else
                this.a.a(str3);
        }
        QcoinActivity.f(this.a).a();
    }
}